package com.yopinclub.activity;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.ImageButton;

import com.yopinclub.R;
import com.yopinclub.YopinClubAvtivity;

public class SpringBoardActivity extends YopinClubAvtivity implements OnClickListener{
	
	ImageButton btnStream;
	ImageButton btnSuggested;
	ImageButton btnPhoto;
	ImageButton btnProfile;
	ImageButton btnEvent;
	ImageButton btnCreate;
	ImageButton btnLeader;
	ImageButton btnMessage;
	Button btnNotification;

	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_springboard);
		setNoTitleBar(false);
		setBackgroundResource(R.drawable.springboard_background);
		
		btnStream = (ImageButton)findViewById(R.id.btn_stream);
		btnStream.setOnClickListener(this);
		btnSuggested = (ImageButton)findViewById(R.id.btn_suggested);
		btnSuggested.setOnClickListener(this);
		btnPhoto = (ImageButton)findViewById(R.id.btn_photo);
		btnPhoto.setOnClickListener(this);
		btnProfile = (ImageButton)findViewById(R.id.btn_profile);
		btnProfile.setOnClickListener(this);
		btnEvent = (ImageButton)findViewById(R.id.btn_event);
		btnEvent.setOnClickListener(this);
		btnCreate = (ImageButton)findViewById(R.id.btn_create);
		btnCreate.setOnClickListener(this);
		btnLeader = (ImageButton)findViewById(R.id.btn_leader);
		btnLeader.setOnClickListener(this);
		btnMessage = (ImageButton)findViewById(R.id.btn_message);
		btnMessage.setOnClickListener(this);
		btnNotification = (Button)findViewById(R.id.btn_notification);
		btnNotification.setOnClickListener(this);
	}

	@Override
	public void onClick(View v) {
		Intent intent = null;
		switch (v.getId()) {
			case R.id.btn_stream:
				intent = new Intent(SpringBoardActivity.this,StreamActivity.class);
				startActivity(intent);
				break;
			case R.id.btn_suggested:
				intent = new Intent(SpringBoardActivity.this,SuggestedActivity.class);
				startActivity(intent);
				break;
			case R.id.btn_photo:
				intent = new Intent(SpringBoardActivity.this,PhotosActivity.class);
				startActivity(intent);
				break;
			case R.id.btn_profile:
				intent = new Intent(SpringBoardActivity.this,ProfileActivity.class);
				startActivity(intent);
				break;
			case R.id.btn_event:
				intent = new Intent(SpringBoardActivity.this,LiveEventsActivity.class);
				startActivity(intent);
				break;
			case R.id.btn_create:
				intent = new Intent(SpringBoardActivity.this,CreateActivity.class);
				startActivity(intent);
				break;
			case R.id.btn_leader:
				intent = new Intent(SpringBoardActivity.this,LeadersActivity.class);
				startActivity(intent);
				break;
			case R.id.btn_message:
				intent = new Intent(SpringBoardActivity.this,MessagesActivity.class);
				startActivity(intent);
				break;
			case R.id.btn_notification:
				intent = new Intent(SpringBoardActivity.this,NotificationsActivity.class);
				startActivity(intent);
				break;
			default:
				break;
		}
	}
}
